package com.opengate.demo.api;

import com.opengate.base.intercept.EnableInterceptor;
import com.opengate.base.stream.RepInput;
import com.opengate.base.stream.RepOutput;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.stream.annotation.EnableBinding;
import org.springframework.cloud.stream.messaging.Sink;
import org.springframework.cloud.stream.messaging.Source;
import org.springframework.transaction.annotation.EnableTransactionManagement;

/**
 * @author 曳戈泰尔
 * @version 1.0
 * @description 启动类
 */
@SpringBootApplication
@EnableInterceptor
@EnableTransactionManagement
@EnableBinding({Sink.class, Source.class, RepInput.class, RepOutput.class})
public class DemoApiApplication {
    public static void main(String[] args) {

        // Nacos 的日志配置是否启用，默认情况下是启用的。
        // 通过将其设置为 false，可以禁用默认的日志配置，从而允许使用自定义的日志配置。
        System.setProperty("nacos.logging.default.config.enabled", "false");

        SpringApplication.run(DemoApiApplication.class, args);
    }
}
